package com.gqz.equip.controller;

import com.gqz.common.core.domain.R;
import com.gqz.equip.api.TEnInterfaceCodeApi;
import com.gqz.equip.service.ITEnInterfaceCodeService;
import com.gqz.equip.vo.TEnInterfaceCodeVo;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class TEnInterfaceCodeController implements TEnInterfaceCodeApi {

    @Autowired
    private ITEnInterfaceCodeService service;


    @PostMapping("/queryLeaf")
    @Operation(summary = "查询字典表", description = "查询字典表")
    @Parameter(name = "code")
    R<List<TEnInterfaceCodeVo>> queryDataPage(@RequestParam(name = "code", required = true) String code) {
        return R.ok(service.queryDictData(code));
    }

}
